package com.shopFund.service.impl;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Select;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.shopFund.bean.UserFund;
import com.shopFund.dao.UserFundMapper;
import com.shopFund.service.IUserFundService;

import shopBean.common.utils.UUIDGenerator;
@Service("userFundService")
public class UserFundServiceImpl implements IUserFundService {
	@Autowired
	UserFundMapper userFundMapper;
	public int insert(UserFund userFund) {
		// TODO Auto-generated method stub
		userFund.setId(UUIDGenerator.generate38());
		return userFundMapper.insert(userFund);
	}

	public UserFund getByUserId(String userId) {
		// TODO Auto-generated method stub
		return userFundMapper.getByUserId(userId);
	}

	public UserFund get(String userId) {
		// TODO Auto-generated method stub
		return userFundMapper.get(userId);
	}

	public int deleteByUserId(String userId) {
		// TODO Auto-generated method stub
		return userFundMapper.deleteByUserId(userId);
	}

}
